Alibabacloud.com offers a wide variety of articles about regular expression metacharacters, easily find your regular expression metacharacters information here online.
The usage of metacharacters in the regular expression tutorial.
This document describes how to use metacharacters in the regular expression tutorial. We will share this with you for your reference. The details are as follows:
Note: In all examples,
The characters in a regular expression are divided into metacharacters and general characters,General charactersMatch itself (what is written, for example, to write 'A' in a regular expression, and match 'A' in a match '), metacharacters are the
Three things ordinary people do not understand: The doctor's prescription, Taoist Ghost, programmer get regular expression What is a regular expression?
Regular expressions, also known as regular expressions, are called regular expression
Special characters in regular expressions
Character implication
\ As a turn, that is, the characters usually after "\" are not interpreted in the original sense, such as the/b/matching character "B", when B is preceded by a backslash/\b/, to
The checksum is all made up of numbers
Funtin Isigit (s) {var patrn=/^[0-9]{1,20}$/; if (!patrn.x (s)) Rturn Fals Rturn Tru}
Javasript Form validation mail to determine whether an input is mailbox mail and implemented through regular expressions.
Replace () is a simple replacement of characters.
ExampleCodeAs follows:
It only replaces the first letter. However, if you add a regular expression, the results will be different! Replace () supports regular expressions. It can match
Oracle's formal expression is implemented in the form of various SQL functions and a WHERE clause operator. If you are unfamiliar with regular expressions, this article will give you an idea of this new, incredibly powerful, yet seemingly mysterious
// Check whether it is composed of digits[Code] function isDigit (s) {var patrn =/^ [0-9] {1, 20} $/; if(! Patrn.exe c (s) return false return true} [/code]
// Check Logon Name: You can enter only 5-20 strings starting with a letter, which can
The regular expression of JSWhether the checksum is all made up of numbersCodefunction IsDigit (s){var patrn=/^[0-9]{1,20}$/;if (!patrn.exec (s)) return falsereturn True}Check login name: Only 5-20 entries begin with a letter, can be numbered, "_", "
What is a regular expression?Regular expressions, also known as formal representations, general representations (English: Regular Expression, often abbreviated as regex, RegExp, or re) in code, are a concept of computer science. A regular expression
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.